home *** CD-ROM | disk | FTP | other *** search
Wrap
# This is a generated file. Do not edit. from template import Handle, fillAttr, quoteAndFillAttr, funcTable from IOBuffer import IOBuffer from xhtmltools import urlencode from templatehelper import quoteattr, escape, evalKey, toUni def fillTemplate(data, domHandler): # Start of handle handle = Handle(domHandler) handle.makeNamedView(u'watchable',u'global view items',None,None,'',u'global filter watchableItems',fillAttr(u'@@@feed getFeedID@@@',data),False,'',u'global sort item',False,data) handle.makeNamedView(u'mylibrary',u'global view items',None,None,'',u'global filter oldItems',fillAttr(u'@@@feed getFeedID@@@',data),False,'',u'global sort item',False,data) handle.makeNamedView(u'newitems',u'global view items',None,None,'',u'global filter recentItems',fillAttr(u'@@@feed getFeedID@@@',data),False,'',u'global sort item',False,data) handle.addView('tmplcomp25160312','nextSibling',handle.findNamedView(u'newitems').getView(),[(0, u'<li t:contextMenu="action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'|Play"'), (3, None), (0, u'\n '), (0, u'\n\n<div class='), (10, u'main-video'), (0, u'>\n\n\n\n\t\n\t<div class='), (10, u'main-video-container'), (0, u'>\n\t\t<div class='), (10, u'main-video-content'), (0, u'>\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-tnail'), (0, u'>\n\t\t\t\t<img src="'), (8, u'this getThumbnail'), (0, u'" alt='), (10, u''), (0, u'></img>\n\t\t\t</div>\n\t\n\t\t\t<div class='), (10, u'main-video-hitbox'), (0, u'>\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'downloading', True, [(0, u'<span class='), (10, u'inprogress'), (0, u'>\n\t\t\t\t\t\t<span title="Downloading \''), (8, u'this getTitle'), (0, u'\'"></span><img src='), (10, u'resource:images/main-video-inprogress-arrows.gif'), (0, u' style='), (10, u'position:absolute; margin: 56px 0px 0px -31px; z-index:4;'), (0, u'></img>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'stopped', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'failed', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'expired', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'autopending', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'manualpending', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'finished', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'watched', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'uploading', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'saved', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-desc'), (0, u'>\n\t\t\t\t<h1>'), (4, u'this getTitle'), (0, u'</h1>\n\t\t\t\t\n\t\t\t\t<div class='), (10, u'main-video-desc-desc'), (0, u'>\n\t\t\t\t<p>'), (5, u'this getDescription'), (0, u'</p>\n\t\t\t\t</div>\n\t\t\t\t\n<span>'), (5, u'this getDetails'), (0, u'</span>\n\n\n\t\t\t\t\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t</div>\n\t</div>\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'stopped', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t\t\n\t\t\t'), (9, (u'global filter boolean', u'this getViewed', '', False, [(0, u'<span>\n\t\t\t\t<div class='), (10, u'main-video-details-new'), (0, u'>\n\t\t\t\t\t<p>New</p>\n\t\t\t\t</div>\n\t\t\t</span>')])), (0, u'\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'expired', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'downloading', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-progress'), (0, u'>\n\t\t\t\t<div class='), (10, u'main-progress-bar'), (0, u'>\n\t\t\t\t\t<img src='), (10, u'resource:images/status.png'), (0, u' height='), (10, u'12'), (0, u' width="'), (2, u'this downloadProgressWidth'), (0, u'"></img>\n\t\t\t\t</div>\n\t\t\t\t<a href='), (10, u'#'), (0, u' class='), (10, u'main-progress-cancel'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');" title='), (10, u'Cancel Download'), (0, u'></a>\n\t\t\t</div>\n\t\t\t<p style='), (10, u'clear:both;'), (0, u'>\n\t\t\t\t<span>'), (4, u'this downloadETA'), (0, u'</span>\n\t\t\t\t'), (9, (u'global filter equal', u'this downloadRate', u'0k/s', False, [(0, u'<span>\n\t\t\t\t\t<span>'), (4, u'this downloadRate'), (0, u'</span>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t</p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'autopending', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p style='), (10, u'clear:both; padding-bottom:3px;'), (0, u'>Pending Auto Download</p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'manualpending', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p style='), (10, u'clear:both; padding-bottom:3px;'), (0, u'>Pending Manual Download</p>\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'finished', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-unwatched'), (0, u'>\n\t\t\t\t\t<p>Unwatched</p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'watched', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-expiry'), (0, u'>\n\t\t\t\t\t<p>Expires: <span>'), (4, u'this getExpirationTime'), (0, u'</span></p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'saved', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t<div style='), (10, u'padding-top:19px;'), (0, u' class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'uploading', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-unwatched'), (0, u'>\n\t\t\t\t\t<p>Unwatched</p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'failed', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p>Download Error: <span>'), (4, u'this getFailureReason'), (0, u'</span></p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n</div>\n\n'), (0, u'\n </li>')], data, u'newitems') handle.addView('tmplcomp55469247','nextSibling',handle.findNamedView(u'mylibrary').getView(),[(0, u'<li t:contextMenu="action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'|Play"'), (3, None), (0, u'\n '), (0, u'\n\n<div class='), (10, u'main-video'), (0, u'>\n\n\n\n\t\n\t<div class='), (10, u'main-video-container'), (0, u'>\n\t\t<div class='), (10, u'main-video-content'), (0, u'>\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-tnail'), (0, u'>\n\t\t\t\t<img src="'), (8, u'this getThumbnail'), (0, u'" alt='), (10, u''), (0, u'></img>\n\t\t\t</div>\n\t\n\t\t\t<div class='), (10, u'main-video-hitbox'), (0, u'>\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'downloading', True, [(0, u'<span class='), (10, u'inprogress'), (0, u'>\n\t\t\t\t\t\t<span title="Downloading \''), (8, u'this getTitle'), (0, u'\'"></span><img src='), (10, u'resource:images/main-video-inprogress-arrows.gif'), (0, u' style='), (10, u'position:absolute; margin: 56px 0px 0px -31px; z-index:4;'), (0, u'></img>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'stopped', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'failed', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'expired', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'autopending', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'manualpending', True, [(0, u'<span class='), (10, u'downloadable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:startDownload?item='), (2, u'this getID'), (0, u'\');" title="Download \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'finished', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'watched', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'uploading', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t\t'), (9, (u'global filter substring', u'this getState', u'saved', True, [(0, u'<span class='), (10, u'playable'), (0, u'>\n\t\t\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:playViewNamed?viewName='), (2, u'thisView'), (0, u'&firstItemId='), (2, u'this getID'), (0, u'\');" title="Play \''), (8, u'this getTitle'), (0, u'\'"></a>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-desc'), (0, u'>\n\t\t\t\t<h1>'), (4, u'this getTitle'), (0, u'</h1>\n\t\t\t\t\n\t\t\t\t<div class='), (10, u'main-video-desc-desc'), (0, u'>\n\t\t\t\t<p>'), (5, u'this getDescription'), (0, u'</p>\n\t\t\t\t</div>\n\t\t\t\t\n<span>'), (5, u'this getDetails'), (0, u'</span>\n\n\n\t\t\t\t\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t</div>\n\t</div>\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'stopped', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t\t\n\t\t\t'), (9, (u'global filter boolean', u'this getViewed', '', False, [(0, u'<span>\n\t\t\t\t<div class='), (10, u'main-video-details-new'), (0, u'>\n\t\t\t\t\t<p>New</p>\n\t\t\t\t</div>\n\t\t\t</span>')])), (0, u'\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'expired', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'downloading', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-progress'), (0, u'>\n\t\t\t\t<div class='), (10, u'main-progress-bar'), (0, u'>\n\t\t\t\t\t<img src='), (10, u'resource:images/status.png'), (0, u' height='), (10, u'12'), (0, u' width="'), (2, u'this downloadProgressWidth'), (0, u'"></img>\n\t\t\t\t</div>\n\t\t\t\t<a href='), (10, u'#'), (0, u' class='), (10, u'main-progress-cancel'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');" title='), (10, u'Cancel Download'), (0, u'></a>\n\t\t\t</div>\n\t\t\t<p style='), (10, u'clear:both;'), (0, u'>\n\t\t\t\t<span>'), (4, u'this downloadETA'), (0, u'</span>\n\t\t\t\t'), (9, (u'global filter equal', u'this downloadRate', u'0k/s', False, [(0, u'<span>\n\t\t\t\t\t<span>'), (4, u'this downloadRate'), (0, u'</span>\n\t\t\t\t</span>')])), (0, u'\n\t\t\t</p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'autopending', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p style='), (10, u'clear:both; padding-bottom:3px;'), (0, u'>Pending Auto Download</p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'manualpending', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p style='), (10, u'clear:both; padding-bottom:3px;'), (0, u'>Pending Manual Download</p>\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'finished', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-unwatched'), (0, u'>\n\t\t\t\t\t<p>Unwatched</p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'watched', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\n\t\t\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-expiry'), (0, u'>\n\t\t\t\t\t<p>Expires: <span>'), (4, u'this getExpirationTime'), (0, u'</span></p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'saved', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t<div style='), (10, u'padding-top:19px;'), (0, u' class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'uploading', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\n\n\t\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t\t\t\t\t\n\t'), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\t\t\t\t\t \n\t\t\t\t<a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:expireItem?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-delete'), (0, u'></img></a>\n\n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<span>\n\t\t\t\t<div class='), (10, u'main-video-details-unwatched'), (0, u'>\n\t\t\t\t\t<p>Unwatched</p>\n\t\t\t\t</div>\n\t\t\t\t<div class='), (10, u'main-video-details-save'), (0, u'>\n\t\t\t\t\t<p><a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:keepItem?item='), (2, u'this getID'), (0, u'\');">Save</a></p>\n\t\t\t\t</div>\n\t\t\t</span>\n\t\t\t\n\t\t\t\n\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\t\n\t\n\t'), (9, (u'global filter substring', u'this getState', u'failed', True, [(0, u'<span>\n\t\t<div class='), (10, u'main-video-details'), (0, u'>\n\t\t\n\t\t\n\t\t\t<div class='), (10, u'main-video-details-tasks'), (0, u'>\n\t\t\t\t '), (9, (u'global filter equal', u'this getURL', u'', False, [(0, u'<a href='), (10, u'#'), (0, u' onclick="recommendItem(\''), (2, u'this getTitle'), (0, u"', '"), (2, u'this getURL'), (0, u"', '"), (2, u'this getFeed getURL'), (0, u'\'); return false;"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'14'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-mail'), (0, u'></img></a>')])), (0, u'\n\t\t\t\t\t <a href='), (10, u'#'), (0, u' onclick="return eventURL(\'action:videoBombExternally?item='), (2, u'this getID'), (0, u'\');"><img src='), (10, u'resource:images/clear.png'), (0, u' height='), (10, u'12'), (0, u' width='), (10, u'13'), (0, u' alt='), (10, u''), (0, u' border='), (10, u'0'), (0, u' class='), (10, u'main-video-details-task-bomb'), (0, u'></img></a> \n\t\t\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t\t\t</div>\n\t\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t<p>Download Error: <span>'), (4, u'this getFailureReason'), (0, u'</span></p>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t</div>\n\t\t<div class='), (10, u'clearer'), (0, u'></div>\n\t</span>')])), (0, u'\n\t\n\t\n\t\n\n</div>\n\n'), (0, u'\n \n </li>')], data, u'mylibrary') # Start of handle handle_0 = Handle(domHandler) handle.addSubHandle(handle_0) # Start of handle handle_1 = Handle(domHandler) handle.addSubHandle(handle_1) out = IOBuffer() out.write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n") out.write(u'<html dtvPlatform="') out.write(quoteattr(urlencode(toUni(evalKey(u'dtvPlatform',data))))) out.write(u'" eventCookie="') out.write(quoteattr(urlencode(toUni(evalKey(u'eventCookie',data))))) out.write(u'" xmlns:t=') out.write(quoteAndFillAttr(u'http://www.participatorypolitics.org/',data)) out.write(u' xmlns=') out.write(quoteAndFillAttr(u'http://www.w3.org/1999/xhtml',data)) out.write(u' xmlns:i18n=') out.write(quoteAndFillAttr(u'http://www.participatoryculture.org/i18n',data)) out.write(u'>\n<head>\n<meta content=') out.write(quoteAndFillAttr(u'text/html; charset=utf-8',data)) out.write(u' http-equiv=') out.write(quoteAndFillAttr(u'content-type',data)) out.write(u'></meta>\n<link href=') out.write(quoteAndFillAttr(u'resource:css/style.css',data)) out.write(u' type=') out.write(quoteAndFillAttr(u'text/css',data)) out.write(u' rel=') out.write(quoteAndFillAttr(u'stylesheet',data)) out.write(u'></link>\n<script type="text/javascript">\n<!-- // Protect from our XML parser, which doesn\'t know to protect <script>\n\n///////////////////////////////////////////////////////////////////////////////\n//// Machinery related to dynamic updates in full XUL mode ////\n///////////////////////////////////////////////////////////////////////////////\n\nfunction handleUpdate(event) {\n r = event.target;\n eval(r.responseText);\n}\n\nfunction beginUpdates() {\n if (getDTVPlatform() == \'xul\') {\n // Under XUL, open a \'push\' HTTP connection to the controller to\n // receive updates. This avoids calling across the Python/XPCOM\n // boundary, which causes deadlocks sometimes for poorly understood\n // reasons.\n // port = getServerPort();\n var cookie = getEventCookie();\n // url = "http://127.0.0.1:" + port + "/dtv/mutators/" + cookie;\n var url = "/dtv/mutators/" + cookie;\n\n var xr = new XMLHttpRequest();\n /*\n netscape.security.PrivilegeManager.\n enablePrivilege("UniversalBrowserRead");\n */\n xr.multipart = true;\n xr.open("GET", url, true);\n xr.onload = handleUpdate;\n xr.send(null);\n }\n}\n \n///////////////////////////////////////////////////////////////////////////////\n//// For use on your page ////\n///////////////////////////////////////////////////////////////////////////////\n\nfunction jsdump(str) {\n Components.classes[\'@mozilla.org/consoleservice;1\']\n\t.getService(Components.interfaces.nsIConsoleService)\t\n\t.logStringMessage(str);\n}\n\nfunction getEventCookie() {\n var elt = document.getElementsByTagName("html")[0];\n return elt.getAttribute(\'eventCookie\');\n}\n\nfunction getDTVPlatform() {\n var elt = document.getElementsByTagName("html")[0];\n return elt.getAttribute(\'dtvPlatform\');\n}\n\n/*\n// NEEDS: eliminate! just use relative URLs\nfunction getServerPort() {\n var elt = document.getElementsByTagName("html")[0];\n return elt.getAttribute(\'serverPort\');\n}\n*/\n\n// For calling from page Javascript: Cause a URL to be loaded. The\n// assumption is that the application will notice, abort the load, and\n// take some action based on the URL.\nfunction eventURL(url) {\n if (getDTVPlatform() == \'xul\') {\n \t// XUL strategy: async HTTP request to our in-process HTTP\n // server. Since it falls under the "same origin" security\n // model exemption, no need for complicated preferences\n // shenanigans -- what a nice day!\n // url = "http://127.0.0.1:" + getServerPort() + "/dtv/action/" +\n // getEventCookie() + "?" + url; NEEDS: remove\n url = "/dtv/action/" + getEventCookie() + "?" + url;\n \tvar req = new XMLHttpRequest();\n req.open("GET", url, true);\n req.send(null);\n // NEEDS: there is another copy of this in main.js.\n }\n else if (typeof(window.frontend) == \'undefined\') {\n\t// Generic strategy: trigger a load, and hope the application\n\t// catches it and cancels it without creating a race\n\t// condition.\n\tdocument.location.href = url;\n } else {\n\t// OS X WebKit (KHTML) strategy: pass in an Objective C object\n\t// through the window object and call a method on it.\n\twindow.frontend.eventURL(url);\n }\n\n return false;\n} \n\n// Open email client with email about selected video\n// All parameters come in URL encoded\nfunction recommendItem(title, url, feedURL) {\n url = URLdecode(url);\n feedURL = URLdecode(feedURL);\n body = "You should check out this video:\\n";\n body = body + url + "\\n\\n";\n body = body + "I found it while using the Democracy Player, which you can download here:\\n";\n body = body + "http://www.getdemocracy.com\\n\\n";\n body = body + "The video was on this channel (click \'subscribe\' in Democracy and paste in this address):\\n"\n body = body + feedURL + "\\n\\n"\n \n url = \'mailto:\';\n url = url + "?subject=" + title;\n url = url + "&body=" + URLencode(body);\n eventURL(url);\n \n return false;\n}\n\n// Change a view\'s filter. The filter controls which records are\n// included and which are not. (You can only do this if, when the view\n// was declared in the page header, it was given an initial filter\n// with the t:filter tag.) viewName is the name of the view whose\n// filter should be changed, as declared in the t:view tag. fieldKey\n// is the property of the record that should be tested (eg, \'name\'.)\n// functionKey is the function that should be used to do the test (eg,\n// \'global filter substring\'.) parameter is an extra parameter to pass\n// to the test function (such as a search string). If invert is true,\n// the sense of the filter is reversed: only objects that don\'t match\n// it will be included. For convenience in \'onclick\' handlers, this\n// function returns false. param is a hack to include a static\n// parameter in addition to the dynamic one.\nfunction setViewFilter(viewName, fieldKey, functionKey, parameter, invert, param) {\n url = \'action:setViewFilter?\';\n url = url + \'viewName=\' + URLencode(viewName);\n url = url + \'&fieldKey=\' + URLencode(fieldKey);\n url = url + \'&functionKey=\' + URLencode(functionKey);\n if (parameter)\n\turl = url + \'¶meter=\' + URLencode(param+\'|\'+parameter);\n else\n\turl = url + \'¶meter=\'+ URLencode(param);\n if (invert)\n\turl = url + \'&invert=true\';\n else\n\turl = url + \'&invert=false\';\n eventURL(url);\n return false;\n}\n\n// Change a view\'s sort. The sort controls the order in which records\n// are displayed. (You can only do this if, when the view was declared\n// in the page header, it was given an initial sort with the t:sort\n// tag.) viewName is the name of the view whose sort should be\n// changed, as declared in the t:view tag. fieldKey is the property of\n// the record to sort on (eg, \'name\'.) functionKey is the comparison\n// function for the sort (eg, \'global sort text\'.) If reverse is true,\n// the records will be shown in the opposite of their normal order as\n// defined by the other parameters. For convenience in \'onclick\'\n// handlers, this function returns false.\nfunction setViewSort(viewName, fieldKey, functionKey, reverse) {\n url = \'action:setViewSort?\';\n url = url + \'viewName=\' + URLencode(viewName);\n url = url + \'&fieldKey=\' + URLencode(fieldKey);\n url = url + \'&functionKey=\' + URLencode(functionKey);\n if (reverse)\n\turl = url + \'&reverse=true\';\n eventURL(url);\n return false;\n}\n\n// Start the video player. The playlist will be the items in the view\n// named by viewName. If firstItemId is the id of an item in the view,\n// playback will start on that item; otherwise playback will start on\n// the first item.\nfunction playViewNamed(viewName, firstItemId) {\n url = \'action:playViewNamed?\';\n url = url + \'viewName=\' + URLencode(viewName);\n url = url + \'&firstItemId=\' + URLencode(firstItemId);\n eventURL(url);\n return false;\n}\n\n// You can make \'incremental search\' text boxes on your page that\n// effectively tie the text box to the \'parameter\' argument of setViewFilter,\n// with the other argumens fixed. To do this, add these two attributes to\n// the text box:\n// onfocus="startEditFilter(this, (viewName), (fieldKey),\n// (functionKey), (invert), (param)"\n// onblur="endEditFilter()"\n// replacing the arguments in parentheses with the desired strings.\n//\n// Note that params is a big hack to pass a static parameter in\n// addition to the dynamic one\n\nvar editFilterTimers = new Array();\nvar editFilterField = null;\nvar editFilterOldValue = \'\';\nvar editFilterCount = 0;\nvar editFilterViews = new Array();\nvar editFilterFieldKeys = new Array();\nvar editFilterFunctionKeys = new Array();\nvar editFilterInverts = new Array();\nvar editFilterParams = new Array();\nvar editCurView = 0;\n\nfunction startEditFilter(obj, views, fieldKeys, functionKeys, inverts, params) {\n editFilterOldValue = obj.value;\n\n editFilterField = obj;\n editFilterViews = views;\n editFilterFieldKeys = fieldKeys;\n editFilterFunctionKeys = functionKeys;\n editFilterInverts = inverts;\n editFilterParams = params;\n editCurView = 0;\n\n editFilterTimerTick(editCurView);\n}\n\nfunction editFilterUpdate(viewName,functionName,fieldName,invert, param) {\n value = editFilterField.value;\n if (editFilterOldValue != value ||\n\teditFilterCount < editFilterViews.length) {\n\tif (editFilterOldValue != value) \n\t editFilterCount = 0;\n\telse\n\t editFilterCount++;\n\tsetViewFilter(viewName, fieldName,\n\t\t functionName, value,\n\t\t invert, param);\n\teditFilterOldValue = value;\n }\n}\n\nfunction editFilterTimerTick(curView) {\n editFilterUpdate(editFilterViews[editCurView],editFilterFunctionKeys[editCurView],editFilterFieldKeys[editCurView],editFilterInverts[editCurView], editFilterParams[editCurView]);\n editCurView++;\n if (editCurView >= editFilterViews.length) {\n\teditCurView = 0;\n }\n editFilterTimer = setTimeout(editFilterTimerTick, 50);\n}\n\nfunction endEditFilter() {\n clearTimeout(editFilterTimer);\n editFilterCount = 0;\n editFilterUpdate();\n}\n\n// Internal use: \'URL encode\' the given string.\nfunction URLencode(str) {\n return encodeURIComponent(str)\n}\n\nfunction URLdecode(str) {\n return decodeURIComponent(str)\n}\n\n///////////////////////////////////////////////////////////////////////////////\n//// For calling by host templating code ////\n///////////////////////////////////////////////////////////////////////////////\n\n// For calling by host templating code: Returns items that should\n// appear in the context click menu in the format url|description with\n// one item on each line. Blank lines are separators\nfunction getContextClickMenu(element) {\n while (1) {\n\tif (element.nodeType == 1 && element.getAttribute(\'t:contextMenu\')) {\n\t ret = element.getAttribute(\'t:contextMenu\');\n\t ret = ret.replace(/\\\\n/g,"\\n");\n\t ret = ret.replace(/\\\\\\\\/g,"\\\\");\n\t return ret;\n\t}\n\tif (element.parentNode)\n\t element = element.parentNode;\n\telse\n\t return "";\n }\n\n // Satisfy Mozilla that the function always returns a\n // value. Otherwise, we get an error if strict mode is enabled,\n // ultimately preventing us from getting the state change event\n // indicating that the load succeeded.\n return "";\n}\n\n// For calling by host templating code: Set CSS styles on the item\n// with the given ID to make it disappear.\nfunction hideItem(id) {\n elt = document.getElementById(id);\n elt.style.display = \'none\';\n forceRedisplay(elt);\n}\n\n// For calling by host templating code: Set CSS styles on the item\n// with the given ID to make it visible if it was previously hidden.\nfunction showItem(id) {\n elt = document.getElementById(id);\n elt.style.display = \'\';\n forceRedisplay(elt);\n}\n\n// For calling by host templating code: Replace the item with the\n// given id with the element described by the proided XML.\nfunction changeItem(id, newXML) {\n elt = document.getElementById(id);\n r = document.createRange();\n r.selectNode(elt);\n frag = r.createContextualFragment(newXML);\n elt.parentNode.replaceChild(frag, elt);\n}\n\n// For calling by host templating code: Parse the XML in newXML into a\n// new element, and insert the new element immediately before the item\n// with the given id, such that the newly inserted item has the same\n// parent.\nfunction addItemBefore(newXML, id) {\n elt = document.getElementById(id);\n r = document.createRange();\n r.selectNode(elt);\n frag = r.createContextualFragment(newXML);\n elt.parentNode.insertBefore(frag, elt);\n} \n\n// For calling by host templating code: Parse the XML in newXML into a\n// new element, and insert the new element as the final child of the\n// item with the given id.\nfunction addItemAtEnd(newXML, id) {\n elt = document.getElementById(id);\n r = document.createRange();\n r.selectNode(elt);\n frag = r.createContextualFragment(newXML);\n elt.insertBefore(frag, null);\n} \n\n// For calling by host templating code: Remove the item with the given\n// id.\nfunction removeItem(id) {\n elt = document.getElementById(id);\n elt.parentNode.removeChild(elt);\n} \n\n// Internal use: Sometime if all you do is change the style on a node,\n// Safari doesn\'t update the view until your mouse is next over the\n// window. Force the issue by making a drastic change in the vicinity\n// of the given element and then reversing it.\nfunction forceRedisplay(elt) {\n r = document.createRange();\n r.selectNode(elt);\n frag = r.extractContents();\n r.insertNode(frag);\n}\n\n///////////////////////////////////////////////////////////////////////////////\n///////////////////////////////////////////////////////////////////////////////\n\n-->\n</script>\n\n<script type="text/javascript">\n <!-- // Protect from our XML parser, which doesn\'t know to protect <script>\n\n function setAutoDownloadableFeed()\n {\n var url = \'action:setAutoDownloadableFeed\';\n url += \'?feed=\' + document.forms[\'setAuto\'][\'feed\'].value;\n if (document.forms[\'setAuto\'].automatic.checked)\n url += \'&automatic=1\';\n else\n url += \'&automatic=0\';\n eventURL(url);\n }\n\n function setAutoDownloadGets()\n {\n var url = "action:setGetEverything";\n var idx = document.forms[\'settings\'][\'autoDownloadGets\'].selectedIndex;\n \n url += \'?feed=\' + document.forms[\'setAuto\'][\'feed\'].value;\n url += "&everything=" + document.forms[\'settings\'][\'autoDownloadGets\'].options[idx].value;\n\n eventURL(url);\n }\n\n function setExpiration()\n {\n var url = "action:setExpiration";\n var idx = document.forms[\'settings\'][\'expireAfter\'].selectedIndex;\n var value = document.forms[\'settings\'][\'expireAfter\'].options[idx].value;\n\n url += \'?feed=\' + document.forms[\'setAuto\'][\'feed\'].value;\n if (value == \'system\' || value == \'never\')\n {\n url += "&type=" + value + "&time=0";\n }\n else\n {\n url += "&type=feed&time=" + value;\n }\n\n eventURL(url);\n }\n\n function setMaxNew()\n {\n var url = "action:setMaxNew";\n\n url += \'?feed=\' + document.forms[\'setAuto\'][\'feed\'].value;\n if (document.forms[\'settings\'][\'maxOutDownloads\'].checked)\n {\n document.forms[\'settings\'][\'maxNew\'].disabled = false;\n url += \'&maxNew=\' + document.forms[\'settings\'][\'maxNew\'].value;\n }\n else\n {\n document.forms[\'settings\'][\'maxNew\'].disabled = true;\n url += \'&maxNew=-1\';\n }\n\n eventURL(url);\n }\n\n -->\n</script>\n\n\n \n \n \n \n \n \n \n \n \n \n \n \n\n\n</head>\n\n<body scroll=') out.write(quoteAndFillAttr(u'yes',data)) out.write(u'>\n <div id=') out.write(quoteAndFillAttr(u'main_window',data)) out.write(u'> \n \n<div id=') out.write(quoteAndFillAttr(u'ultra_top_wrapper',data)) out.write(u'>\n\n<div id=') out.write(quoteAndFillAttr(u'top_wrapper',data)) out.write(u'>\n\n<div id=') out.write(quoteAndFillAttr(u'channel_info',data)) out.write(u'>\n\t<img src="') out.write(quoteattr(toUni(evalKey(u'feed getThumbnail',data)))) out.write(u'"></img>\n\t<h2 i18n:translate=') out.write(quoteAndFillAttr(u'',data)) out.write(u'><span>') out.write(toUni(evalKey(u'feed getTitle',data))) out.write(u'</span></h2>\n\t<a href="mailto:?subject=') out.write(quoteattr(urlencode(toUni(evalKey(u'feed getTitle',data))))) out.write(u'&body=%0D%0A%0D%0AYou should check out the Internet TV channel "') out.write(quoteattr(urlencode(toUni(evalKey(u'feed getTitle',data))))) out.write(u"". If you don't have the Democracy Player, you can get it here:%0D%0A%0D%0Ahttp://www.getdemocracy.com/%0D%0A%0D%0AAnd then subscribe to this channel:%0D%0A%0D%0A") out.write(quoteattr(urlencode(toUni(evalKey(u'feed getURL',data))))) out.write(u'" class=') out.write(quoteAndFillAttr(u'recommend_link',data)) out.write(u' i18n:translate=') out.write(quoteAndFillAttr(u'',data)) out.write(u'>Recommend to Friends</a>\n</div>\n\n<div id=') out.write(quoteAndFillAttr(u'right_half',data)) out.write(u'>\n <form name=') out.write(quoteAndFillAttr(u'setAuto',data)) out.write(u'>\n <input type=') out.write(quoteAndFillAttr(u'hidden',data)) out.write(u' name=') out.write(quoteAndFillAttr(u'feed',data)) out.write(u' value="') out.write(quoteattr(urlencode(toUni(evalKey(u'feed getID',data))))) out.write(u'"></input>\n ') if evalKey(u'global filter boolean', data)(evalKey(u'feed isAutoDownloadable', data), ''): for (func, args) in [(0, u'<input checked='), (10, u'checked'), (0, u' name='), (10, u'automatic'), (0, u' value='), (10, u'1'), (0, u' onClick='), (10, u'javascript:setAutoDownloadableFeed()'), (0, u' type='), (10, u'checkbox'), (0, u'></input>')]: out.write(funcTable[func](data,'',args)) out.write(u'\n ') if not evalKey(u'global filter boolean', data)(evalKey(u'feed isAutoDownloadable', data), ''): for (func, args) in [(0, u'<input name='), (10, u'automatic'), (0, u' value='), (10, u'1'), (0, u' onClick='), (10, u'javascript:setAutoDownloadableFeed()'), (0, u' type='), (10, u'checkbox'), (0, u'></input>')]: out.write(funcTable[func](data,'',args)) out.write(u'\n <span class=') out.write(quoteAndFillAttr(u'auto_link',data)) out.write(u' i18n:translate=') out.write(quoteAndFillAttr(u'',data)) out.write(u'>AUTO DOWNLOAD</span>\n </form>\n\t<a href=') out.write(quoteAndFillAttr(u'#',data)) out.write(u' class=') out.write(quoteAndFillAttr(u'settings_link',data)) out.write(u' i18n:translate=') out.write(quoteAndFillAttr(u'',data)) out.write(u' onclick=') out.write(quoteAndFillAttr(u"eventURL('template:feed-settings');",data)) out.write(u'>Change Settings</a>\n</div>\n\n\t<br style=') out.write(quoteAndFillAttr(u'clear: both; height: 0; padding: 0; margin: 0;',data)) out.write(u'></br>\n</div>\n\n\n\n<div id=') out.write(quoteAndFillAttr(u'navigation_wrapper',data)) out.write(u'>\n\n\t<div class=') out.write(quoteAndFillAttr(u'search_wrap',data)) out.write(u'><input onfocus="startEditFilter(this,new Array(\'newitems\',\'mylibrary\'),new Array(\'\',\'\'),new Array(\'global filter recentItems\',\'global filter oldItems\'),new Array(0,0),new Array(\'') out.write(quoteattr(urlencode(toUni(evalKey(u'feed getFeedID',data))))) out.write(u"','") out.write(quoteattr(urlencode(toUni(evalKey(u'feed getFeedID',data))))) out.write(u'\'))" type=') out.write(quoteAndFillAttr(u'text',data)) out.write(u' class=') out.write(quoteAndFillAttr(u'search_field',data)) out.write(u' onblur=') out.write(quoteAndFillAttr(u'endEditFilter()',data)) out.write(u' size=') out.write(quoteAndFillAttr(u'17',data)) out.write(u'></input></div>\n\n\t<div id=') out.write(quoteAndFillAttr(u'navigation',data)) out.write(u'>\n\t<div id=') out.write(quoteAndFillAttr(u'tabs',data)) out.write(u' class=') out.write(quoteAndFillAttr(u'tabs',data)) out.write(u'>\n\t\t\n\t\t<span class=') out.write(quoteAndFillAttr(u'tab_left',data)) out.write(u'><a href=') out.write(quoteAndFillAttr(u'',data)) out.write(u' class=') out.write(quoteAndFillAttr(u'watch_active',data)) out.write(u'>Watch</a></span>\n\t\t\n\t\t') if evalKey(u'global filter boolean', data)(evalKey(u'feed hasLibrary', data), ''): for (func, args) in [(0, u'<span class='), (10, u'tab-center'), (0, u'><a href='), (10, u'#'), (0, u' class='), (10, u'browse'), (0, u' onclick='), (10, u"eventURL('template:feed-choose');"), (0, u'>Browse</a></span>')]: out.write(funcTable[func](data,'',args)) out.write(u'\n\t\t\n\t\t') if not evalKey(u'global filter boolean', data)(evalKey(u'feed hasLibrary', data), ''): for (func, args) in [(0, u'<span class='), (10, u'tab_right'), (0, u'><a href='), (10, u'#'), (0, u' class='), (10, u'browse_nolibrary'), (0, u' onclick='), (10, u"eventURL('template:feed-choose');"), (0, u'>Browse</a></span>')]: out.write(funcTable[func](data,'',args)) out.write(u'\n\t\t\n\t\t') if evalKey(u'global filter boolean', data)(evalKey(u'feed hasLibrary', data), ''): for (func, args) in [(0, u'<span class='), (10, u'tab_right'), (0, u'><a href='), (10, u''), (0, u' class='), (10, u'library'), (0, u'>Library</a></span>')]: out.write(funcTable[func](data,'',args)) out.write(u'\n\t\n\t</div>\n\t</div>\n\n</div>\n\n</div>\n\n \n \n \n \n <div id=') out.write(quoteAndFillAttr(u'content_window',data)) out.write(u'>\n \n \n <ul> \n\n') out.write("<div") out.write(" class=") out.write(quoteAndFillAttr("no_new",data)) out.write(" i18n:translate=") out.write(quoteAndFillAttr("",data)) out.write(" id=\"tmplcomp92438134\"") if handle.findNamedView("watchable").getView().len() > 0: out.write(" style=\"display:none\">") else: out.write(">") handle.addHideIfEmpty('tmplcomp92438134',u'watchable',True) out.write(u'<a href=') out.write(quoteAndFillAttr(u'template:feed-choose',data)) out.write(u'>See what\'s on this channel by clicking \'Browse\'</a></div> \n\n<span id="tmplcomp25160312"/> \n <li class=') out.write(quoteAndFillAttr(u'divider',data)) out.write(u' i18n:translate=') out.write(quoteAndFillAttr(u'',data)) out.write(u'>SAVED IN MY COLLECTION</li> \n <span id="tmplcomp55469247"/> \n </ul>\n </div>\n </div> \n\n<div class=') out.write(quoteAndFillAttr(u'bottom_strip',data)) out.write(u'>\nThanks for trying the beta release of the Democracy Player. It still has some <a href=') out.write(quoteAndFillAttr(u'http://participatoryculture.org/dtv_faq.php#known_bugs',data)) out.write(u">bugs</a>, but we're working on them. <a href=") out.write(quoteAndFillAttr(u'mailto:feedback@ppolitics.org?Subject=Democracy Player Beta Feedback',data)) out.write(u'>Send us your feedback</a>! (<a href=') out.write(quoteAndFillAttr(u"mailto:feedback@ppolitics.org?body=Dear Participatory ____(noun)____,%0A%0A I downloaded Democracy Player so that I could ____(verb)____ some ____(noun)____. But when I ____(verb, past tense)____ the ____(noun)____ everything went totally ____(adjective)_____. You guys really need to ____(verb)____ your ____(noun)____ together.%0A%0AI'll see you ____(time or location)____,%0A%0A _____(your name)_____",data)) out.write(u'>mad libs version</a>)\n</div>\n\n\n\n\n</body>\n</html>') out.close() return (out, handle)